<%@ page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c-rt"%>
<%@ include file="/taglibs.jsp"%>
<%@	page import="com.yaodian100.core.common.utils.ServerValue"%>
<c-rt:set var="midContextPath" value='<%=ServerValue.getMidContextPath()%>'/>
<s:actionerror/>
<s:actionmessage/>
<s:fielderror />
<script type="text/javascript">
$().ready(function() {
	doAR('${midContextPath}/coupon/listCouponItem.do?AJAX=true&refreshZone=couponItemList&couponUuid=${couponUuid}','couponItemList');
});
</script>
<h1>Coupon 检视</h1>
<s:form action="save.do" method="post" id="formObj">

<table class="tb-data" id="mainTable" >
	<tbody>
		<tr>
			<th>代码<BR>（此内容为用户可见）</th>
			<td>
				${couponUuid}
				<s:hidden name="couponUuid"/>
			</td>
		</tr>
		<tr>
			<th>名称<BR>（此内容为用户可见）</th>
			<td>
				${name}
				<s:hidden name="name"/>
			</td>
		</tr>
		<tr>
			<th>叙述</th>
			<td>
				${description}
				<s:hidden name="description"/>
			</td>
		</tr>
			<tr>
			<th>生效起</th>
			<td>
				${startDate}
				<s:hidden name="startDate"/>
			</td>
		</tr>
			<tr>
			<th>生效迄</th>
			<td>
				${endDate}
				<s:hidden name="endDate"/>
			</td>
		</tr>
		<tr>
			<th>相关活动连结</th>
			<td>
				<s:hidden name="activityLink"/>
				<s:if test="%{activityLink == null or activityLink == ''}">
					无
				</s:if>
				<s:else>
					${activityLink}
				</s:else>
			</td>
		</tr>
		<tr>
			<th>适用范围</th>
			<td>
				${applyRangTypeMenu.options[applyRangeTypeStr].name}
				<s:hidden name="applyRangeTypeStr"/>
			</td>
		</tr>
		<tr>
			<th>范围设定
			</th>
			<td>
				${applyRangeTypeExtensionDisplay}
				<!--先把編輯時要先在欄位裡顯示的範圍設定值先偷偷放在這裡-->
				<s:hidden name="applyRangeTypeExtension" value="%{applyRangeTypeExtensionEditDisplayInitial}" ></s:hidden>
			</td>
		</tr>
		<tr>
			<th>礼券面额</th>
			<td>
				¥ ${faceValue}
				<s:hidden name="faceValue"/>
			</td>
		</tr>
		<tr>
			<th>最低商品价格</th>
			<td>
				¥ ${minimumProductPrice}
				<s:hidden name="minimumProductPrice"/>
			</td>
		</tr>
		<tr>
			<th>状态</th>
			<td>
				${statusMenu.options[statusStr].name}
				<s:hidden name="statusStr"/>
			</td>
		</tr>
		<tr>
			<th>数量</th>
			<td>
				${amount}
				<s:hidden name="amount"/>
			</td>
		</tr>
		<tr>
			<th>单一帐号限用一次<BR>（限定用户能否使用多张同批礼券）</th>
			<td>
				<s:if test="%{isOnce}">
					是
				</s:if>
				<s:else>
					否
				</s:else>
				<s:hidden name="isOnce"/>
			</td>
		</tr>
		<tr class="tb-data">
		<th>预算归属</th>
		<td>
			${menuBudget.options[coupon.budget].name}
			<s:hidden name="budget"/>
		</td>
		</tr>
		<tr>
			<th>建立人</th>
			<td>
				${coupon.createUser} / <fmt:formatDate value="${coupon.createDate}" pattern="yyyy-MM-dd HH:mm:ss" />			
			</td>
		</tr>
		<tr>
			<th>修改者</th>
			<td>
				${coupon.modifyUser} / <fmt:formatDate value="${coupon.modifyDate}" pattern="yyyy-MM-dd HH:mm:ss" />			
			</td>
		</tr>
	</tbody>
</table>

<div class="f-link">
	<a href="search.do">回查询页</a>
	<a href="#" onclick="document.formObj.action='edit.do';document.formObj.submit();">修改</a>
	<a href="#" onclick="document.formObj.action='delete.do';document.formObj.submit();">删除</a>
	<a href="#" onclick="document.formObj.action='exportCouponItemCodeList.do';document.formObj.submit();">券号汇出</a>
</div>
<br/><br/><br/><br/>
<div id="couponItemList"></div>
</s:form>